﻿using Xunit;

namespace CSharpLogger.UnitTest
{
    /// <summary>
    /// Test /<see cref="ILoggerHandlerFactory"/> implementation
    /// </summary>
    public class LoggerHandlerFactoryUnitTest : CSharpLoggerUnitTestBase
    {
        /// <summary>
        /// Initialize test configuration
        /// </summary>
        public LoggerHandlerFactoryUnitTest()
        {
            base.Init();
        }

        /// <summary>
        /// Tests default GetHandler()(
        /// </summary>
        [Fact]
        public void GetHandlerTest()
        {
            //arrange
            var handler = new LoggerHandlerFactory();

            //act
            var logger = handler.GetHandler<FileLogger>();

            //assert
            Assert.Equal(logger.GetType(), typeof(FileLogger));
        }
    }
}
